Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a custom Press type with a block and the meta boxes to configure it #35

Closed
wants to merge 2 commits into from

Conversation

otakupahp
Copy link
Collaborator

This creates a new CPT called Press Items (#34) with a Press Type category

imagen

imagen

A press item could be either internal or external:

  • Internal: Have blocks stored in the page content and doesn't have a Press Link
  • External: Doesn't need block content, but must have a Press Link

When an external press item is visited, it will be redirected to the external source

The press item information must be added in the item sidebar
imagen

All press items require: content, cover image, outlet, author and press type
imagen

If any of those are missing, the press item can't be saved
imagen

The plugin creates a Singles Press template to show the internal press items
imagen

It also adds a pattern that can be added anywhere
imagen

The pattern uses a new block "Press Release fields" to shows either the Press Outlet or the Press Author
imagen

This block could be added a Prefix and Suffix
imagen
imagen

The block work with the new no-reload query
https://github.com/user-attachments/assets/369b8834-69c2-4b72-bd86-d79bfa256bfe

@otakupahp otakupahp requested a review from tommusrhodus January 2, 2025 14:34
@nate-allen
Copy link
Contributor

@otakupahp - Thanks for submitting a PR. The monorepo is intended for broadly reusable blocks, while this PR focuses on a project-specific post type ("Press"). We recommend moving this implementation in the project’s private repo instead of here in the monorepo. Let me know if you have any questions or need a hand.

@nate-allen nate-allen closed this Jan 7, 2025
@otakupahp
Copy link
Collaborator Author

Hi, @nate-allen.

Originally, this was just one client request, but after talking to @dhanson-wp, he agreed that it's a recurring requirement for projects.

In fact, currently, I'm working on another project that also requires this

Would you consider accepting this as a necessary recurring feature?

@tommusrhodus
Copy link
Contributor

@otakupahp it doesn't fit the structure or purpose of a blocks-only monorepo.

I agree however that we need to keep track of plugins like yours in a better way generally, much like we already do with simple events for example, but this monorepo isn't the place for it.

@otakupahp
Copy link
Collaborator Author

I understand, so is it ok to PR this in the original repo created for this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants